package com.qf.mybatis.dao;

import cn.hutool.core.io.FileUtil;
import com.qf.mybatis03.entity.Book;
import org.junit.Test;

import java.util.ArrayList;
import java.util.List;

public class BookRandom {
    @Test
    public void randomBookTest() {

        List<String> books = new ArrayList<>();
        //Book book = new Book(2,"think1","nothink","earth",2);
        for (int i = 0; i < 500000; i++) {
            String s = 2+i+","+"think"+i+","+"nothink"+","+"earth"+","+1;
            books.add(s);
        }
        FileUtil.appendLines(books,"E:\\QianFengInformation\\text\\books.txt","utf-8");
    }
}
